passthrough: give XEN_DOMCTL_test_assign_device more sane semantics
authorJan Beulich <jbeulich@suse.com>
Mon, 28 Aug 2017 08:48:55 +0000 (10:48 +0200)
committerJan Beulich <jbeulich@suse.com>
Mon, 28 Aug 2017 08:48:55 +0000 (10:48 +0200)
commit4f88c4870861259edb1a507ddcb26d4201b0562d
tree4efe91bc0204d009207becccd45a21646a2eb6d0
parent803c5a2a42e7c72a4c848e0f0106a941b758a91f
passthrough: give XEN_DOMCTL_test_assign_device more sane semantics

So far callers of the libxc interface passed in a domain ID which was
then ignored in the hypervisor. Instead, make the hypervisor honor it
(accepting DOMID_INVALID to obtain original behavior), allowing to
query whether a device can be assigned to a particular domain. Do this
by folding the assign and test-assign paths.

Drop XSM's test_assign_{,dt}device hooks as no longer being
individually useful.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Daniel De Graaf <dgdegra@tycho.nsa.gov>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
xen/common/domctl.c
xen/drivers/passthrough/device_tree.c
xen/drivers/passthrough/pci.c
xen/include/public/domctl.h
xen/include/xsm/dummy.h
xen/include/xsm/xsm.h
xen/xsm/dummy.c
xen/xsm/flask/hooks.c